<div class="contents">
  <ol class="breadcrumb">
    <li><a href="#/index/panel">首页</a></li>
    <li class="active">app首页推荐</li>
  </ol>
  <div class="form-inline search-box">
    <div class="form-group">
      <label class="sr-only">产品类别</label>
      <select class="form-control" ng-model="meida.productType" ng-options="m.value as m.text for m in productTypeModel">
        <option value="">--选择产品类别--</option>
      </select>
    </div>
    <div class="form-group">
      <label class="sr-only" >产品名称</label>
      <input type="text" class="form-control" placeholder="产品名称" ng-model="meida.productName">
    </div>
    <div class="form-group" style="width: 300px;">
      <label class="sr-only">选择产品</label>
      
      <select class="form-control" ng-if="meida.productType != '01'" ng-model="meida.productCode" ng-options="p.pCode as p.pName for p in meida.productList | filter:meida.productName" style="width: 100%;">
        <option value="">--选择选择产品--</option>
      </select>

      <select class="form-control" ng-if="meida.productType == '01'" ng-model="meida.productCode" ng-options="p.id as p.jjmc for p in meida.productList | filter:meida.productName" style="width: 100%;">
        <option value="">--选择选择产品--</option>
      </select>
    </div>
    <div class="form-group">
      <select class="form-control"ng-model="meida.recommentType" ng-options="a.value as a.text for a in dictMap.recommentTypeModel">
        <option value="">--推荐位置--</option>
      </select>
    </div>
    <button type="button" class="btn btn-primary" ng-click="mediaAddRecommend()">添加</button>
  </div>
  <table class="table table-striped table-hover">
    <thead>
      <tr>
        <th width="50"></th>
        <th width="80">产品类型</th>
        <th width="200">产品名称</th>
        <th width="90">推荐位置</th>
        <th width="150">添加时间</th>
        <th width="100">操作</th>
      </tr>
    </thead>
    <tbody>
      <tr ng-repeat="l in list">
        <td>{{$index + 1}}</td>
        <td>{{l.productType | productTypeRender}}</td>
        <td>{{l.pName || l.jjmc}}</td>
        <td>{{l.recommentType | recommentTypeModelRenter}}</td>
        <td>{{l.createDate | date : 'yyyy-MM-dd HH:mm:ss'}}</td>
        <td class="optd">
          <a class="cur-p" ng-click="delete(l.id)">删除</a>
        </td>
      </tr>
    </tbody>
  </table>

  <div class="pager-box" ng-include src="'tpl/public/pager.html'" ng-show="list.length > 0"></div>
</div>

<div class="layer-box" ng-show="loading">
  <div class="layer-bg"></div>
  <div class="layer-con " style="padding:10px 20px;background: none; color: #fff; font-size: 28px;">
    LOADING...
  </div>
</div> 